package edu.jamestang.yeb.entity;

import cn.afterturn.easypoi.excel.annotation.Excel;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * @author JamesTang
 * @date 2021/12/14 23:52
 */
@Data
@EqualsAndHashCode(callSuper = false, of = "name")
@RequiredArgsConstructor
@NoArgsConstructor
@TableName(value = "t_joblevel")
@ApiModel(value = "JobLevel object")
public class JobLevel implements Serializable {

    @ApiModelProperty(value = "id")
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "LevelName")
    @Excel(name = "职称")
    @NonNull
    private String name;

    @ApiModelProperty(value = "jobLevel")
    @TableField(value = "titleLevel")
    private String titleLevel;

    @ApiModelProperty(value = "createTime")
    @TableField(value = "createDate")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "Asia/Shanghai")
    private LocalDateTime createDate;

    @ApiModelProperty(value = "enabled")
    private Boolean enabled;

}
